package com.wenyl.juc.thread.saleTickets;

/**
 * @author Swimming Dragon
 * @description: TODO
 * @date 2024年11月07日 11:42
 */
public class Test {
    public static void main(String[] args) {
        Tickets tickets = new Tickets(100);
        CustomerRunnable[] customerRunnables = new CustomerRunnable[100];
        Thread[] threads = new Thread[100];
        for(int i=0;i<100;i++){
            customerRunnables[i] = new CustomerRunnable(tickets);
            threads[i] = new Thread(customerRunnables[i]);
            threads[i].start();
        }
    }
}
